<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<!DOCTYPE html >
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<meta name="format-detection" content="telephone=no">
	<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0,user-scalable=no">
	<meta name="apple-mobile-web-app-capable" content="yes">
	<meta name="apple-mobile-web-app-status-bar-style" content="black">
	<link rel="stylesheet" type="text/css" media="screen" href="${ROOT_PATH }content/scripts/bootstrap/css/bootstrap.min.css">
	<title>员工信息</title>
	<script src="${ROOT_PATH }content/scripts/jquery-1.10.1.min.js"></script>
	<script src="${ROOT_PATH }content/scripts/jquery.form.js"></script>
	<script src="${ROOT_PATH }content/scripts/juery.hammer.js"></script>
	<script src="${ROOT_PATH }content/scripts/bootstrap/js/bootstrap.min.js"></script>
	<style type="text/css">
		*{ font-size:16px;}
		html{height: 100%;}
		body{
			background:url(${ROOT_PATH }content/images/front/amani1_02.png) no-repeat;background-size: 100% 100%;
			color:#fff;
		}
	</style>
</head>
<body>
	<section>
		<form action="${ROOT_PATH }Staff/index/upload" name="stafform" id="stafform" method="post">
			<div style="text-align: center;">
				<c:set var="head" value="${ROOT_PATH }content/images/front/cycle.png"/>
				<c:if test="${!empty staff.imageurl.value }">
					<c:set var="head" value="${staff.imageurl.value }"/>	
				</c:if>
				<img src="${head }" class="img-circle" width="200px" style="margin: auto;">
			</div>
			
			<div id="info" style="padding:20px;">
				<div>昵称：<input name="hm" type="text" value="${staff.staffename.value }" style="background: none;"/></div>
				<div>门店：${staff.commpanyName.value }</div>
				<div>职位：${staff.position.value }</div>
				<div>姓名：${staff.staffname.value }</div>
				<div>手机：${staff.mobilephone.value }</div>
				<div>身份证：${staff.pccid.value }</div>
				<input name="image" type="file" accept="image/jpeg,image/x-png" value="" />
				<div><input name="sub" type="submit" value="确认" style="color: #000;"></div>
			</div>
			
		</form>
	</section>
	<script type="text/javascript">
	$(function () {
        $('#stafform').submit(function () {
        	var options = {
				beforeSubmit: function () {
                    //验证
                },
                dataType: 'json',
                success: function (txt) {
                    if (txt.isok) {
                        alert("保存成功");
                        location.reload(true);
                        return false;
                    } else {
                    	alert(txt.data);
                        return false;
                    }
                }
            };
            $('#stafform').ajaxSubmit(options);
            return false;
        });
	});
	</script>
</body>
</html>